import { NgModule } from '@angular/core';
import { PreloadAllModules, RouterModule, Routes } from '@angular/router';

const routes: Routes = [
  {
    path: 'tabs',
    loadChildren: () => import('./pages/tabs/tabs.module').then(m => m.TabsPageModule)
  },
  // {
  //   path: 'user',
  //   loadChildren: () => import('./pages/user/user.module').then( m => m.UserPageModule)
  // },
  // {
  //   path: 'identity',
  //   loadChildren: () => import('./pages/identity/identity.module').then( m => m.IdentityPageModule)
  // },
  // {
  //   path: 'register',
  //   loadChildren: () => import('./pages/register/register.module').then( m => m.RegisterPageModule)
  // },
  {
    path: '',
    loadChildren: () => import('./pages/login/login.module').then( m => m.LoginPageModule)
  },
  {
    path: '*',
    loadChildren: () => import('./pages/login/login.module').then( m => m.LoginPageModule)
  },
  // {
  //   path: '*',
  //   loadChildren: () => import('./pages/tabs/tabs.module').then(m => m.TabsPageModule)
  // },
  // {
  //   path: '',
  //   loadChildren: () => import('./pages/tabs/tabs.module').then(m => m.TabsPageModule)
  // },
  {
    path: 'login',
    loadChildren: () => import('./pages/login/login.module').then( m => m.LoginPageModule)
  },
  {
    path: 'verification-phone',
    loadChildren: () => import('./pages/verification-phone/verification-phone.module').then( m => m.VerificationPhonePageModule)
  },
  {
    path: 'reset-password',
    loadChildren: () => import('./pages/reset-password/reset-password.module').then( m => m.ResetPasswordPageModule)
  },
  {
    path: 'setting',
    loadChildren: () => import('./pages/setting/setting.module').then( m => m.SettingPageModule)
  },
  {
    path: 'change-phone',
    loadChildren: () => import('./pages/change-phone/change-phone.module').then( m => m.ChangePhonePageModule)
  },
  {
    path: 'qr-code',
    loadChildren: () => import('./pages/qr-code/qr-code.module').then( m => m.QrCodePageModule)
  },
  {
    path: 'certificate-list',
    loadChildren: () => import('./pages/certificate-list/certificate-list.module').then( m => m.CertificateListPageModule)
  },
  {
    path: 'certificate-detail',
    loadChildren: () => import('./pages/certificate-detail/certificate-detail.module').then( m => m.CertificateDetailPageModule)
  },
  {
    path: 'search-user',
    loadChildren: () => import('./pages/search-user/search-user.module').then( m => m.SearchUserPageModule)
  },
  {
    path: 'identity-authentication',
    loadChildren: () => import('./pages/identity-authentication/identity-authentication.module').then( m => m.IdentityAuthenticationPageModule)
  },
  {
    path: 'code-info',
    loadChildren: () => import('./pages/code-info/code-info.module').then( m => m.CodeInfoPageModule)
  },
  {
    path: 'scan-code',
    loadChildren: () => import('./pages/scan-code/scan-code.module').then( m => m.ScanCodePageModule)
  },
  {
    path: 'news',
    loadChildren: () => import('./pages/news/news.module').then( m => m.NewsPageModule)
  },
  {
    path: 'new-detail',
    loadChildren: () => import('./pages/new-detail/new-detail.module').then( m => m.NewDetailPageModule)
  },
  {
    path: 'application',
    loadChildren: () => import('./pages/application/application.module').then( m => m.ApplicationPageModule)
  },
];
@NgModule({
  imports: [
    RouterModule.forRoot(routes, { preloadingStrategy: PreloadAllModules, useHash: true })
  ],
  exports: [RouterModule]
})
export class AppRoutingModule {}
